//以下为按需引入ElementUI时的配置，需安装 cnpm install babel-plugin-component -D
//并在babel.config.js添加相应配置
import Vue from 'vue';
import {
    Avatar,
    Dialog,
    Menu,
    Submenu,
    MenuItem,
    Drawer,
    Backtop,
    Link,
    Icon,
    Divider,
    Input,
    Dropdown,
    DropdownMenu,
    DropdownItem,
    Form,
    FormItem,
    Button,
    Upload,
    Popconfirm,
    Pagination,

    Loading,
    MessageBox,
    Message,
    Notification
} from 'element-ui';


Vue.use(Avatar);
Vue.use(Dialog);
Vue.use(Menu);
Vue.use(Submenu);
Vue.use(MenuItem);
Vue.use(Drawer);
Vue.use(Backtop);
Vue.use(Link);
Vue.use(Icon);
Vue.use(Divider);
Vue.use(Input);
Vue.use(Dropdown);
Vue.use(DropdownMenu);
Vue.use(DropdownItem);
Vue.use(Form);
Vue.use(FormItem);
Vue.use(Button);
Vue.use(Upload);
Vue.use(Popconfirm);
Vue.use(Pagination);

Vue.use(Loading.directive);

Vue.prototype.$ELEMENT = { zIndex: 3000 };  //弹框的Z-index
Vue.prototype.$confirm = MessageBox.confirm;
Vue.prototype.$prompt = MessageBox.prompt;
Vue.prototype.$notify = Notification;
Vue.prototype.$message = Message;
